# coding: utf-8
from application import db
from common.models.user import User


class InterviewComment(db.Model):
    __tablename__ = 'interview_comment'

    id = db.Column(db.Integer, primary_key=True)
    userid = db.Column(db.String(30, 'utf8mb4_0900_ai_ci'), db.ForeignKey('user.userid'))
    interviewid = db.Column(db.Integer)
    score = db.Column(db.Integer)
    comment = db.Column(db.TEXT)
    posterid = db.Column(db.String(30, 'utf8mb4_0900_ai_ci'))
    user = db.relationship('User', foreign_keys=userid)
    isagree = db.Column(db.String(30, 'utf8mb4_0900_ai_ci'))

    minemploydate=db.Column(db.Date)
    maxemploydate = db.Column(db.Date)
    minsalary=db.Column(db.Integer)
    maxsalary = db.Column(db.Integer)

    updated_time = db.Column(db.DateTime)
    created_time = db.Column(db.DateTime)
